<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
</head>
<body>
<div id="app18">
    <!--<li v-for="item in items" :key="item.message">
        {{ otherMsg }} {{ item.message }}
    </li>-->
    <!--还可以展示当前项的索引-->
    <!--<li v-for="(item,index) in items" :key="item.message">
        {{ otherMsg }} {{ index }} {{ item.message }}
    </li>-->
    <li v-for="(value,name,index) in object">
        {{ index }} {{ name }} {{ value }}
    </li>
</div>

<script type="text/javascript">
    var app = new Vue({
        el: '#app18',
        data: {
            otherMsg:'hello',
            items: [
                { message: 'Foo' },
                { message: 'Bar' }
            ],
            object: {
                title: 'fuck',
                author: 'the',
                time: 'world'
            }
        }
    })
</script>
</body>
</html>
